package dynamicproxy.cglib;

/**
 * @Author liangbaigao
 * @Date 2023/9/30 9:10
 */
public class Client {

    public static void main(String[] args) {
        UserServiceImpl userService = new UserServiceImpl();
        System.out.println("代理前");
        System.out.println(userService.getClass() +"\r\n");

        CglibProxy cglibProxy = new CglibProxy(userService);
        UserServiceImpl instance = (UserServiceImpl) cglibProxy.getInstance();
        System.out.println("代理后");
        System.out.println(instance.getClass());
        instance.findUserList();
    }
}
